<!DOCTYPE html>
<html lang="en">
<head>
	<meta charset="UTF-8">
	<title>调出合同查询</title>
	<link rel="stylesheet" href="css/reset.css">
	<link rel="stylesheet" href="css/product.css">
	<link rel="stylesheet" href="css/select.css">
	<style>
		.main-bg1{
			padding-bottom: 0px;
		}
		.content-table-three tbody tr td {
		    max-width: 350px;
		    min-width: 100px;
		}
		.content-table-three thead tr td span {
	    	color: #4d5971;
		    display: inline-block;
		    word-wrap: break-word;
		    width: auto;
		    line-height: 20px;
		    vertical-align: top;
		    margin-top: 10px;
		}
		.content-table-three tbody tr td p {
		    text-align: right;
		    padding-left: 12px;
		}
		.content-table-three tbody tr td span{
			padding-right: 12px;
		}
		.content-table-three thead tr td:nth-child(2) span {
		    color: #4d5971;
		    display: inline-block;
		    word-wrap: break-word;
		    width: 300px;
		    line-height: 20px;
		    vertical-align: top;
		    margin-top: 10px;
		}
		.content-table-three thead tr td:last-child {
		    line-height: 40px;
		    background: #F9FBFF;
		    text-align: right;
		    padding-right: 12px;
		}
		.content-table-three thead tr td:last-child span {
		    color: #4d5971;
		    display: inline-block;
		    width: auto;
		    line-height: 20px;
		    vertical-align: top;
		    margin-top: 10px;
		}
		.content-table-three tbody tr td:nth-child(1){
			width: 190px;
		}
		.content-table-three tbody tr td:nth-child(2){
			width: 160px;
		}
		.content-table-three tbody tr td:nth-child(3){
			width: 150px;
		}
		.content-table-three tbody tr td:nth-child(4){
			width: 220px;
		}
		.content-table-three tbody tr td:nth-child(5){
			width: 200px;
		}
		.content-table-three tbody tr td:nth-child(6){
			width: 100px !important;
			min-width: 70px;
		}
		.content-table-three tbody tr td:nth-child(1) span{
			width: 100px;
		}
		.content-table-three tbody tr td:nth-child(2) span{
			width: 70px;
		}
		.content-table-three tbody tr td:nth-child(3) span{
			width: 70px;
		}
		.content-table-three tbody tr td:nth-child(4) span{
			width: 130px;
		}
		.content-table-three tbody tr td:nth-child(5) span{
			width: 115px;
		}
		.content-table-three tbody tr:nth-child(2) td p {
		    text-align: left;
		}
		.content-table-three tbody tr:nth-child(2) td p>span {
		    width: auto;
		}
		.color-operation:hover {
		    text-decoration:underline; 
		    cursor: pointer;
		}
		.content-btn {
		    padding-bottom: 5px;
		}
		.content-btn> .btn-style-two{
			float: right;
			margin-left: 8px;
		}
		.export-btn {
		    float: left;
		    margin-top: 0px;
		    margin-right: 12px;
		}
		.newset-btn {
		    position: absolute;
		    top: -20px;
		}
		.product-child-content {
		    position: relative;
		    margin-bottom: 20px;
		}
		.content-form input {
		    width: 120px;
		}
	</style>
</head>
<body>
	<div class="main-content">
		<div class="main-bg1">
			<ul class="product-title clearfix">
				<li><a href="redeploymentContract.html">可调配合同查询</a></li>
				<li><a href="inTransferContract.html">调入合同查询</a></li>
				<li class="title-active"><a class="color-operation" href="outTransferContract.html">调出合同查询</a></li>
			</ul>
			<div class="product-content clearfix">
				<!-- 费用清单 -->
				<div class="product-child">
					<div class="product-child-content">
						<p class="content-title matop">调出合同查询</p>
						<a href="addAllocation.html" class="newset-btn icon-add clearfix matop">+&nbsp;新增调配</a>
						<form id="seachContractInboundForm">
						<div class="content-form">
							<ul>
								<li><span class="text-name">快递单号：</span><input name="tracknumber" type="text"></li>
								<li><span class="text-name">调入部门：</span><input  name="addressee" type="text"></li>
								<li><span class="text-name">调配状态：</span>
								<select class="multiselect" name="status" id="single">
									<option value="">已签收</option>
									<option value="">未签收</option>
									<option value="">已撤回</option>
								</select></li>
								<li><span class="text-name">项目名称：</span><input name="contractInbound.projectname "  type="text"></li>
								<li><button class="btn-style-two" type="button" id="seachContractInbound">搜索</button><i class="btn-operation maleft20">重置</i></li>
							</ul>
						</div>
						</form>
						<div class="content-list">
							<div class="info-list" dataTableTable = "true" bindClick = "seachContractInbound" bindForm = "seachContractInboundForm"  dataAction = "/expressInformation/findListByType">
								<table class="content-table-three" cellspacing="0" cellpadding="0">
									<thead>
										<tr>
											<td>项目编号：<span name  = "contractInbound.projectcode" type = "table" ></span></td>
											<td colspan="4">项目名称：<span  name  = "contractInbound.projectname" type = "table" ></span></td>
											<td></td>
										</tr>
									</thead>
									<tbody>
										<tr>
											<td>
												<p>调入部门：<span  name  = "addressee" type = "table" ></span></p>
												<p>调出部门：<span  name  = "tractaddress" type = "table" ></span></p>
											</td>
											<td>
												<p>调配状态：<span name = "status" type = "dict" dictType = "status"></span></p>
												<p>调配数量：<span  name  = "expressInbound.number" type = "table" ></span></p>
											</td>
											<td>
												<p>创建人：<span  name  = "updateBy" type = "table" ></span></p>
												<p>收件人：<span  name  = "signBy" type = "table" ></span></p>
											</td>
											<td>
												<p>创建时间：<span  name  = "updateDate" type = "table" ></span></p>
												<p>签收时间：<span  name  = "signDate" type = "table" ></span></p>
											</td>
											<td>
												<p>合同编号：<span  name  = "expressInbound.contractnumber" type = "table" ></span></p>
												<p>快递单号：<span class="color-operation" onclick="seeLogistics()"  name  = "tracknumber" type = "table"></span></p>
											</td>
											<td>
												<a class="btn-operation" href="updAllocation.html">编辑</a>
												<i class="btn-operation" onclick="del()">撤销调配</i>
											</td>
										</tr>
										<tr>
											<td colspan="6">
												<p>退回说明：<span name  = "reason" type = "table" ></span></p>
											</td>
										</tr>
									</tbody>
								</table>								
							</div>
						</div>
					</div>	
				</div>
			</div>
		</div>		
	</div>
	<script src="js/jquery-3.2.1.min.js"></script>
	<script type="text/javascript" src="lib/layer/2.4/layer.js"></script>
	<script src="js/select.jquery.js"></script>
	<script type="text/javascript" src = "js/util.js"></script>
	<script type="text/javascript" src = "js/tableTable.js"></script>
	<script>
		$('.multiselect').multiselect({setMaxOptionNum:4,selectedHtmlValue:''});
		$('#single').multiselect({multiple:false,selectedHtmlValue:'待审核',setWidth: 140+'px'});
		 function seeLogistics(){
        	parent.layer.open({
			      type: 2,
			      title: '查看物流',
			      shadeClose: true,
			      shade: 0.2,
			      maxmin: true, //开启最大化最小化按钮
			      area: ['870px', '450px'],
			      content: 'seeLogistics.html'
			    });
        } 
        function del(my){
       	 my = $(my);
       	var index = my.parent().parent().parent().parent().find("input[name='index']").val();
       	var data = $("div[dataTableTable = 'true']").getAllTableData()[index];
      	parent.setData(data);
        	parent.layer.open({
			      type: 2,
			      title: '撤销确认',
			      shadeClose: true,
			      shade: 0.2,
			      maxmin: true, //开启最大化最小化按钮
			      area: ['400px', '250px'],
			      content: 'revocationAllocation.html'
			    });
        }
        function getHeight(){
            var myiframeH=$(".main-content").height();
            var _parent=$(window.parent.document);
            _parent.find('body').css('height',(myiframeH+150)+'px');
            _parent.find('.main-position').css('height',(myiframeH+100)+'px');
        };
        $('.main-content').resize(function(){
            getHeight();
        });
        function tableCallBack(my){
        	var data =  my.getAllTableData();
        	data.forEach(function(value,i){
        		var $tr = my.find('tbody').eq(1).children('tr').eq(i).find('td:last');
        		$tr.append('<i class="btn-operation" onclick="seeLogistics(this)">查看物流</i>');
        		if(value.status == 0){
        			$tr.append('<i class="btn-operation" onclick="del(this)">撤销调配</i>');
        		}		
        	})        
        }
	</script>
</body>
</html>